﻿using PrimeTween;
using UnityEngine;

namespace Combat
{
    public class RocketLauncher : MonoBehaviour, ILauncher
    {
        [SerializeField] private Rocket rocketPrefab;
        
        
        public void Fire(Vector3 muzzlePosition, Vector3 atDirection, Vector3 atPosition, Team team)
        {
            Rocket rocket = Instantiate(rocketPrefab, muzzlePosition, Quaternion.identity);
            rocket.Launch(atPosition, team);
        }
    }
}